/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.eleric.rememome.type;

/**
 *
 * @author MWaldman
 */
public enum MemoStatusType
{
    OPEN(1),
    CLOSED(2);
    private int statusId;

    private MemoStatusType(int statusId)
    {
        this.statusId = statusId;
    }

    public int getStatusId()
    {
        return statusId;
    }

    public void setStatusId(int statusId)
    {
        this.statusId = statusId;
    }

    static public MemoStatusType getStatus(int id)
    {
        for (MemoStatusType st : MemoStatusType.values())
        {
            if (st.getStatusId() == id)
            {
                return st;
            }
        }
        return null;
    }
}
